'use strict';

const Controller = require('egg').Controller;

class ClassifyController extends Controller {
    async lClassify() {
        let {ctx,service} = this;
        let lClassify = await service.classify.lClassify();
        ctx.body = {
            code:1,
            data:lClassify
        }
    }

    //获取右侧数据
    async rClassify(){
        let {ctx,service} = this;
        let {pid} = ctx.query;
        let rClassify = await service.classify.rClassify(pid);

        ctx.body = {
            code:1,
            data:rClassify
        }
    }
}

module.exports = ClassifyController;
